home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 34
/
Aminet 34 (2000)(Schatztruhe)[!][Dec 1999].iso
/
Aminet
/
comm
/
irc
/
cybershiela.lha
/
cs
/
csc_ping.amirx
< prev
next >
Wrap
Text File
|
1999-07-10
|
1KB
|
67 lines
/* shiela ping responder */
Options Results
signal on syntax
ponger=getclip('PONGER')
nick=getclip('NICK')
if ponger=1 then do;'say Ping is in Use atm...Please try again in a moment after i report this poing.';exit;end
call setclip('PONGER','1')
getusers
allusers=result
x=pos(nick,upper(allusers))
if x<1 then signal nouser
call time('R')
'say /ping 'nick
HuHuhLoopit:
krv=time('E')
if krv>150 then signal timeout
getmynick
mynick=result
'userhost 'mynick
myhost=result
xxk=pos('@',myhost)
myfront=substr(myhost,1,xxk-1)
drop comm
drop dest
drop text
drop prefix
drop nick
drop rest
getchannel
channam=Upper(result)
'getline'
text=line
prefix=line.prefix
comm=line.command
dest=line.dest
rest=line.rest
xv=pos('!',prefix,1)
if xv>0 then do;nick=left(prefix,xv-1);end
msgr=nick
if upper(left(comm,4))="NOTI" then signal NOTICE
signal huhuhloopit
nouser:
'say no such user exist'
call setclip('PONGER','0')
exit
NOTICE:
getmynick
mynick=upper(result)
xv=pos('!',prefix,1)
if xv>0 then do;nick=left(prefix,xv-1);end
if upper(nick)=upper(msgr) then signal morenotice
signal huhuhloopit
MORENOTICE:
krv=time('E')
'say Ping For 'nick' is 'krv'sec.'
call setclip('PONGER','0')
exit
TIMEOUT:
'say lag on 'nick' was more than 150 seconds aborting'
call setclip('PONGER','0')
exit